 <div class="top">
    <table>
      <tbody><tr>
        <!-- <td><img width="120" onload="120&lt;=this.width?this.width=120:this.width;90&lt;=this.height?this.height=90:this.height" alt="上海抚生实业有限公司" src="http://img16.hbzhan.com/1/20120208/634643114658100000.jpg" id="zhantai_logo"></td> -->
        <td>
        {dede:field name='typeid' runphp='yes'}
		global $dsql;
		$typeid = @me;
		$query = "SELECT topid, content FROM dede_arctype where id = $typeid";
		$rs = $dsql->GetOne($query);
		$cur_id = $rs['topid'];
		
		if(0 == $cur_id){
			$web_title = $rs['content'];
		} else {
			$query = "SELECT content FROM dede_arctype where id = $cur_id";
			$rs = $dsql->GetOne($query);
			$web_title = $rs['content'];
		}
		
		@me = $web_title;
		{/dede:field}          
          </td>
      </tr>
    </tbody></table>    
  </div>
  <div class="menu">
    <p>
{dede:field name='typeid' runphp='yes'}
	global $dsql;
	$typeid = @me;
	$query = "SELECT * FROM dede_arctype where id = $typeid";
	$row = $dsql->GetOne($query);
	$cur_id = $row['topid'];
	
	if(0 == $cur_id){
		$link = GetTypeUrl($row['typeid'],MfTypedir($row['typedir']),$row['isdefault'],$row['defaultname'],$row['ispart'],$row['namerule2'],$row['moresite'],$row['siteurl'],$row['sitepath']);
	} else {
		$query = "SELECT * FROM dede_arctype where id = $cur_id";
		$row = $dsql->GetOne($query);
		$link = GetTypeUrl($row['typeid'],MfTypedir($row['typedir']),$row['isdefault'],$row['defaultname'],$row['ispart'],$row['namerule2'],$row['moresite'],$row['siteurl'],$row['sitepath']);
	}
	
	@me = "<a href='{$link}'>首页</a>";
{/dede:field}      
{dede:field name='typeid' runphp='yes'}
	global $dsql;
	$typeid = @me;
	
	$query = "SELECT id, reid FROM dede_arctype where id = $typeid";
	$rs = $dsql->GetOne($query);
	
	if(0 == $rs['reid']) {
		$cur_reid = $rs['id'];
	} else {
		$cur_reid = $rs['reid'];
	}
	
	$query = "SELECT id, reid FROM dede_arctype where id = $cur_reid";
	$rs = $dsql->GetOne($query);
	$reid = $rs['reid'];
	
	if(0 == $reid) {
		$reid = $cur_reid;
		$pid = $typeid;
	} else {
		$pid = $rs['id'];
	}
	
	//$query2 = "SELECT * FROM dede_arctype where reid = $reid and id != $pid order by sortrank limit 3, 9";
	$query2 = "SELECT * FROM dede_arctype where reid = $reid order by sortrank limit 3, 9";
	$dsql->Execute('me',$query2);
	
	$s = '';
	
	while ($row = $dsql->GetArray('me')) {
		$typename = $row['typename'];
		$link = GetTypeUrl($row['typeid'],MfTypedir($row['typedir']),$row['isdefault'],$row['defaultname'],$row['ispart'],$row['namerule2'],$row['moresite'],$row['siteurl'],$row['sitepath']);
		$s .= "<a href='{$link}'>$typename</a>";
	}
	
	@me = $s;
{/dede:field}
    <!-- <a id="cpzx" class="drop" href="/st71654/product.html">产品中心</a><a href="/st71654/news.html">公司新闻</a><a href="/st71654/sale.html">供求商机</a><a id="jszx" class="drop" href="/st71654/tech.html">技术中心</a><a href="/st71654/intro.html">公司介绍</a><a href="/st71654/honor.html">荣誉资质</a><a href="/st71654/job.html">人才招聘</a><a class="nobor" href="/st71654/contactus.html">联系我们</a> -->
    </p>
        <span>    
        {dede:field name='typeid' runphp='yes'}
		global $dsql;
		$typeid = @me;
		$query = "SELECT * FROM dede_arctype where id = $typeid";
		$rs = $dsql->GetOne($query);
		$topid = $rs['topid'];

		if(0 == $topid) {
			$topid = $rs['id'];
		} 
		
		$query = "SELECT content FROM dede_arctype where topid = $topid and typename = '联系QQ'";
		$rs = $dsql->GetOne($query);
		$content = trim(html2text($rs['content']));
		@me = "<a href='tencent://message/?uin={$content}&amp;Menu=yes' ref='nofollow' target='blank'>QQ联系</a>";
		{/dede:field}
    </span>
 <!--        <ul id="ulcpzx" style="display: none;">
      <li><a href="/st71654/catalog.html">产品目录</a></li>
      <li><a href="/st71654/price.html">产品报价</a></li>
    </ul>
    <ul id="uljszx" class="xiala_1" style="display: none;">
      <li><a href="/st71654/article.html">技术文章</a></li>
      <li><a href="/st71654/info.html">资料下载</a></li>
    </ul> -->
    <script language="javascript" type="text/javascript">
    /*
        jQuery("#ulcpzx").hide();
        jQuery("#uljszx").hide();
        jQuery("#cpzx").hover(
        function () { jQuery("#ulcpzx").show(); },
        function () { jQuery("#ulcpzx").hide(); }
        );
        jQuery("#ulcpzx").hover(
        function () { jQuery("#ulcpzx").show(); },
        function () { jQuery("#ulcpzx").hide(); }
        );

        jQuery("#jszx").hover(
        function () { jQuery("#uljszx").show(); },
        function () { jQuery("#uljszx").hide(); }
        );
        jQuery("#uljszx").hover(
        function () { jQuery("#uljszx").show(); },
        function () { jQuery("#uljszx").hide(); }
        );
        */
    </script>
  </div>  